function Verification() {
    var Ver = 0;
    var $verAll = $('body').find("[class*=verification]");
    var allRules = {
        phone: {regex: /^(\(\d{3,4}\)|\d{3,4}-)?\d{7,8}$/g},
        postcode: {regex: /^\d{6}$/g},
        mobile: {regex: /^(\d{11}|[0\+]\d+)$/g},
        email: {regex: /^([a-zA-Z0-9]+[_|\_|\.|-]?)*[a-zA-Z0-9]+@([a-zA-Z0-9]+[_|\_|\.|-]?)*[a-zA-Z0-9]+\.[a-zA-Z]{2,3}$/g},
        date: {regex: [/^\d{4}-\d{2}-\d{2}$/g, /^\d{4}\/\d{2}\/\d{2}$/g]},
        NoString: {regex: /^\d+(?=\.{0,1}\d+$|$)/},
        Special: {regex:  new RegExp("[`~!@#$^&*()=|{}':;',\\[\\].<>/?~！@#￥……&*（）——|{}【】‘；：”“'。，、？]")}
    };
    $verAll.each(function (i, d) {
        var ClassAll = $(d).attr("class"),
            ClassTextAll = /verification\[(.*)\]/.exec(ClassAll);
        if (!ClassTextAll) {
            return false
        }
        var Vitem = ClassTextAll[1].split(/\[|,|\]/);
        for (var i = 0; i < Vitem.length; i++) {
            Vitem[i] = Vitem[i].replace(" ", "");
            if (Vitem[i] === "") {
                delete Vitem[i]
            }
        }
        for (var i = 0; i < Vitem.length; i++) {
            switch (Vitem[i]) {
                case"required":
                    if ($(d).val().trim() == "") {
                        $(this).addClass('check-error').siblings('.tips').text('*'+$(d).attr('data-info') + "值不能为空")
                        return false;
                    } else {
                      $(this).removeClass('check-error').siblings('.tips').text('')
                    }
                    break;
                case"minNum":
                    var Num = Vitem[i + 1], NumV = parseFloat($(d).val());
                    if (NumV < Num) {
                      $(this).addClass('check-error').siblings('.tips').text('*'+$(d).attr('data-info') + "值不能小于" + Num)
                        return false
                    } else {
                       $(this).removeClass('check-error').siblings('.tips').text('')
                    }
                    break;
                case"maxNum":
                    var Num = Vitem[i + 1], NumV = parseFloat($(d).val());
                    if (NumV > Num) {
                      $(this).addClass('check-error').siblings('.tips').text('*'+$(d).attr('data-info') + "值不能大于" + Num)
                        return false
                    } else {
                      $(this).removeClass('check-error').siblings('.tips').text('')
                    }
                    break;
                case"maxSize":
                    var Num = Vitem[i + 1], NumV = $(d).val().length;
                    if (NumV > Num) {
                      $(this).addClass('check-error').siblings('.tips').text('*'+$(d).attr('data-info') + "长度不能大于" + Num)
                        return false
                    } else {
                      $(this).removeClass('check-error').siblings('.tips').text('')
                    }
                    break;
                case"minSize":
                    var Num = Vitem[i + 1], NumV = $(d).val().length;
                    if (NumV < Num) {
                      $(this).addClass('check-error').siblings('.tips').text('*'+$(d).attr('data-info') + "长度不能小于" + Num)
                        return false
                    } else {
                      $(this).removeClass('check-error').siblings('.tips').text('')
                    }
                    break;
                case"MustChoose":
                    var checkedV = $(d).find('input:checked').length
                    if (checkedV == 0) {
                        layer.msg('请选择' + $(d).attr('data-info'), {icon: 0, time: 1000});
                       $(this).addClass('check-error').siblings('.tips').text('*'+'请选择' + $(d).attr('data-info'))
                      return false
                    }else{
                      $(this).removeClass('check-error').siblings('.tips').text('')
                    }
                    break;
                case"NotSpecial":
                    var checkedV = $(d).val();
                    if (allRules.Special.regex.test(checkedV)) {
                      $(this).addClass('check-error').siblings('.tips').text('*'+$(d).attr('data-info')+'不能含特殊字符')
                        return false
                    }else{
                      $(this).removeClass('check-error').siblings('.tips').text('')
                    }
                    break;
                case"MustSelect":
                    var selectV = $(d).val();
                    if (selectV == 0 || selectV == undefined) {
                        $(this).addClass('check-error').siblings('.tips').text('*'+'请选择' + $(d).attr('data-info'))
                        return false
                    } else {
                      $(this).removeClass('check-error').siblings('.tips').text('')
                    }
                    break;
                case"mobile":
                    var mobileV = $(d).val();
                    if (!allRules.mobile.regex.test(mobileV)) {
                        $(this).addClass('check-error').siblings('.tips').text('*'+$(d).attr('data-info') + "格式不正确")
                        return false
                    } else {
                      $(this).removeClass('check-error').siblings('.tips').text('')
                    }
                    break;
                case"email":
                    var emailV = $(d).val();
                    if (!allRules.email.regex.test(emailV)) {
                        $(this).addClass('check-error').siblings('.tips').text('*'+$(d).attr('data-info') + "格式不正确")
                        return false
                    } else {
                      $(this).removeClass('check-error').siblings('.tips').text('')
                    }
                    break;
                case'Number':
                    var NumV = $(d).val();
                    if (!allRules.mobile.regex.test(NumV)) {
                      $(this).addClass('check-error').siblings('.tips').text('*'+$(d).attr('data-info') + "必须是数字和小数点")
                        return false
                    } else {
                      $(this).removeClass('check-error').siblings('.tips').text('')
                    }
                    break;
                default:
                    break
            }
        }
        Ver++;
    })
    return Ver == $verAll.length ? true : false
}
// 只能输入数字方法
function clearNoNum(obj) {
    obj.value = obj.value.replace(/[^\d.]/g, "");  //清除“数字”和“.”以外的字符
    obj.value = obj.value.replace(/\.{2,}/g, "."); //只保留第一个. 清除多余的
    obj.value = obj.value.replace(".", "$#$").replace(/\./g, "").replace("$#$", ".");
    obj.value = obj.value.replace(/^(\-)*(\d+)\.(\d\d).*$/, '$1$2.$3');//只能输入两个小数
    if (obj.value.indexOf(".") < 0 && obj.value != "") {//以上已经过滤，此处控制的是如果没有小数点，首位不能为类似于 01、02的金额
        obj.value = parseFloat(obj.value);
    }
}